import FSMBlackboard from "./FSMBlackboard";

export default class FSMCondition<T> {
    public dataName: string;
    public targetValue: T;
    protected _currValue: T;

    constructor(name: string, value?: T) {
        this.dataName = name;
        this.targetValue = value;
    }

    public tick(data: FSMBlackboard) {
        this._currValue = data.getData(this.dataName);
        return true;
    }
}